package top.orange.picacg.model;

import xyz.erupt.annotation.Erupt;
import xyz.erupt.annotation.EruptField;
import xyz.erupt.annotation.sub_erupt.Power;
import xyz.erupt.annotation.sub_field.Edit;
import xyz.erupt.annotation.sub_field.View;
import xyz.erupt.annotation.sub_field.sub_edit.Search;
import xyz.erupt.jpa.model.BaseModel;

import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * @author dell
 */

@Erupt(
        name = "图片分类表",
        power = @Power(importable = true, export = true)
)
@Table(name = "p_type")
@Entity
public class TypeModel extends BaseModel {

    @EruptField(
            views = @View(title = "类型名称"),
            edit = @Edit(title = "类型名称", search = @Search)
    )
    private String name;

    @EruptField(
            views = @View(title = "显示顺序"),
            edit = @Edit(title = "显示顺序")
    )
    private Integer sort;
}
